From d88b0c530fabb745d97eece0e2bdaa7386bea203 Mon Sep 17 00:00:00 2001 From: robertl Date: Fri, 5 May 2006 14:32:48 +0000 Subject: [PATCH] Make use of isnan optional since it's C99. git-svn-id: http://gpsbabel.googlecode.com/svn/trunk@1999 f51c46e8-681c-474f-0cfe-069cfd0219fb --- gpsbabel/grtcirc.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gpsbabel/grtcirc.c b/gpsbabel/grtcirc.c index 752e3f229..2bb40b0b2 100644 --- a/gpsbabel/grtcirc.c +++ b/gpsbabel/grtcirc.c @@ -68,7 +68,12 @@ double gcdist( double lat1, double lon1, double lat2, double lon2 ) { res = acos(res); - if ((isnan(res)) || (errno == EDOM)) { /* this should never happen: */ + if ( +#if defined isnan + /* This is a C99-ism. */ + (isnan(res)) || +#endif + (errno == EDOM)) { /* this should never happen: */ errno = 0; /* Math argument out of domain of function, */ return 0; /* or value returned is not a number */ } -- 2.30.2